import java.util.Random;

public class J02Random {
    public static void main(String[] args) {
        Random r = new Random();

        // 0 <= r < 100
        // [0,100)
        // [ 闭区间   ）开区间
        // [2,4]  (3,7]
        //0 ~ 99  整数
        for (int i = 0; i < 100; i++) {
            int num = r.nextInt(100);
            System.out.println("num = " + num);
        }

    }
}

/*
[0,10)   0 <= x <10
0+5 <= x+5 < 10+5
5 <= x+5 < 15

 */

class Random2{
    public static void main(String[] args) {
        Random r = new Random();

        for (int i = 0; i < 10; i++) {
            //[0,13)
            int num = r.nextInt(13);
            //[5,18)
            num += 5;
            System.out.println(num);
        }

    }
}